package cate.game.train.inscription.msg;

import cate.common.annotation.OperationSetter;
import cate.common.table.d.GDOperation;
import cate.game.GameBody;
import cate.game.client.ClientContext;
import cate.game.client.msg.ClientMsg;
import cate.game.client.msg.MsgConfig;
import cate.game.client.msg.MsgInput;
import cate.game.client.msg.id.MsgIdBTrain;
import easy.java.dev.note.NoteField;

import java.util.List;

@ClientMsg(title = "铭文从铭文页卸下 的 请求")
@OperationSetter(GDOperation.INSCRIPTION_OFF)
public class InscriptionOffReq implements MsgInput {

    @NoteField("铭文页id")
    public int id;
    @NoteField(value = "部位ID", detail = "要脱的部位")
    public List<Byte> posList;

    @Override
    public MsgConfig conf() {
        return MsgIdBTrain.INSCRIPTION_OFF_REQ;
    }

    @Override
    public void execute(GameBody game, ClientContext cc) {
        game.train.inscription.inscriptionOff(cc.getRole(), id, posList);
    }
}
